import { defineStore } from 'pinia';

import { DashboardAgencyApi } from '/@/api/locality/agency';
import { store } from '/@/store';

interface DashboardData {
  userInfo: any;
}

export const AgencyStore = defineStore({
  id: 'app-Agency',
  state: (): DashboardData => ({
    userInfo: null,
  }),
  getters: {},
  actions: {
    async GetDashboardAgency(params) {
      const data = DashboardAgencyApi(params);
      return data;
    },
  },
});

export function useUserStoreWithOut() {
  return AgencyStore(store);
}
